package com.xyy.saas.payment.dao.model;

import lombok.Getter;
import lombok.Setter;
import java.util.Date;

@Getter
@Setter
public class RefundReturnAdvance {
    /**
     * 自增ID
     */
    private Long id;
    /**
     * 渠道
     */
    private String channel;
    /**
     * 业务类型
     */
    private String businessType;
    /**
     * 订单类型
     */
    private String businessOrderType;
    /**
     * 退款单号
     */
    private String refundNo;
    /**
     * 垫资回补单号
     */
    private String returnAdvanceNo;
    /**
     * 垫资回补金额
     */
    private Integer returnAmount;
    /**
     * 出款方账号
     */
    private String payerAccount;
    /**
     * 入款方账号
     */
    private String payeeAccount;
    /**
     * 垫付回补结果
     * 枚举值：
     * SUCCESS：回补成功
     * FAILED：回补失败
     * PROCESSING：处理中
     */
    private String status;
    /**
     * 备注
     */
    private String message;
    /**
     * 更新时间
     */
    private Date updateTime;
    /**
     * 创建时间
     */
    private Date createTime;

    /**
     * 构建对象
     * @param id
     * @param status
     * @param message
     * @return
     */
    public static RefundReturnAdvance build(Long id, String status, String message) {
        RefundReturnAdvance returnAdvance = new RefundReturnAdvance();
        returnAdvance.setId(id);
        returnAdvance.setStatus(status);
        returnAdvance.setMessage(message);
        return returnAdvance;
    }
}
